package com.sky.mapper;

import com.github.pagehelper.Page;
import com.sky.annotation.AutoFill;
import com.sky.dto.CategoryPageQueryDTO;
import com.sky.entity.Category;
import com.sky.enumeration.OperationType;
import org.apache.ibatis.annotations.Mapper;

import java.util.List;

/*分类Mapper接口*/
@Mapper // mapper层接口
public interface CategoryMapper {
    @AutoFill(value = OperationType.INSERT)
    public void insert(Category category);

    public Page<Category> pageQuery(CategoryPageQueryDTO categoryPageQueryDTO);

    public void deteleById(Long id);

    @AutoFill(value = OperationType.UPDATE)
    public void update(Category category);

    public List<Category> list(Integer type);
}
